package com.tianfeng.fenghuotoutiao.ui.activity.AppListActibity;

import android.support.v4.app.Fragment;
import android.support.v4.app.FragmentManager;
import android.support.v4.app.FragmentPagerAdapter;

import java.util.List;

/**
 * Created by DELL on 2018/3/26.
 */

public class MyOrderPagerAdapter extends FragmentPagerAdapter {

    private List<Fragment> list;

    public MyOrderPagerAdapter(FragmentManager fm, List<Fragment> list) {
        super(fm);
        this.list = list;
    }

    @Override
    public Fragment getItem(int position) {
        return list.get(position);
    }

    @Override
    public int getCount() {
        return list.size();
    }

    @Override
    public CharSequence getPageTitle(int position) {
        if (position == 0) {
            return "游戏赚钱";
        } else if (position == 1) {
            return "官网红包群";
        }
        return "";
    }
}
